package cn.Service.Impl;

import cn.Mapper.IndexMapper;
import cn.Service.IndexService;
import cn.entity.Category;
import cn.entity.Product;
import cn.entity.Product_copy;
import cn.entity.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class IndexServiceImpl implements IndexService {
    @Autowired IndexMapper indexMapper;

    public List<Product> FindproductListByisHot() {
        return indexMapper.FindproductListByisHot();
    }

    public List<Product> FindproductListByTime() {
        return indexMapper.FindproductListByTime();
    }

    public List<Product> FindproductListBypbargain() {
        return indexMapper.FindproductListBypbargain();
    }

    public List<Category> FindCategoryAll() {
        return indexMapper.FindCategoryAll();
    }

    public Product FindProductItemByPid(Integer pid) {
        return indexMapper.FindProductItemByPid(pid);
    }

    public int LittleData(Integer pid) {
        return indexMapper.LittleData(pid);
    }

    public int AddProduct(Product product) {
        return indexMapper.AddProduct(product);
    }

    public List<Product_copy> FindAllProduct_copy() {
        return indexMapper.FindAllProduct_copy();
    }

    public Product_copy FindProduct_copyByPid(Integer pid) {
        return indexMapper.FindProduct_copyByPid(pid);
    }

    public int DeleteProduct_copyByPid(Integer pid) {
        return indexMapper.DeleteProduct_copyByPid(pid);
    }

    public int Deleteproduct_copy() {
        return indexMapper.Deleteproduct_copy();
    }

    public List<User> FindCommentByPid(Integer pid) {
        return indexMapper.FindCommentByPid(pid);
    }

    public int FindCount(Integer pid) {
        return indexMapper.FindCount(pid);
    }
}
